﻿@model CloudFranceTriple.Models.PrivateMessageBoxSet

@{
    ViewBag.Title = CloudFranceTriple.WebRole.Properties.Resources.PrivateMessageDeleteTitle;
    Layout = "~/Views/Shared/_Layout.cshtml";
}
@Html.Action("Create", "PrivateMessageRead", new { area = "Forum", id = Model.Id, id2 = new CloudFranceTriple.WebRole.WebSecurityWrapper().CurrentUserId })
<div class="content-padding">
    <h1>@CloudFranceTriple.WebRole.Properties.Resources.PrivateMessageDeleteTitle</h1>
    <h3>@CloudFranceTriple.WebRole.Properties.Resources.QuestionDelete</h3>
    <section>
        <fieldset>
            <legend>PrivateMessageBoxSet</legend>
            <div class="display-label">
                @CloudFranceTriple.WebRole.Properties.Resources.PrivateMessageSubject
            </div>
            <div class="display-field">
                @Html.DisplayFor(model => model.MessageBody_Label)
            </div>

            <div class="display-label">
                @CloudFranceTriple.WebRole.Properties.Resources.PrivateMessageAuthor
            </div>
            <div class="display-field">
                @Html.DisplayFor(model => model.MessageBody_Author)
            </div>

            <div class="display-label">
                @CloudFranceTriple.WebRole.Properties.Resources.PrivateMessageTo
            </div>
            <div class="display-field">
                @(new CloudFranceTriple.WebRole.Models.UsersContext().UserProfiles.Find(Model.ToPrivateMessage).UserName)
            </div>

            <div class="display-label">
                @CloudFranceTriple.WebRole.Properties.Resources.PrivateMessageCreationDate
            </div>
            <div class="display-field">
                @Html.DisplayFor(model => model.MessageBody_CreationDate, "TemplateUserDateTime")
            </div>

            <div class="display-label">
                @CloudFranceTriple.WebRole.Properties.Resources.PrivateMessageBody
            </div>
            <div class="display-field">
                @Html.DisplayTextFor(model => model.MessageBody_Message)
            </div>
        </fieldset>
        @using (Html.BeginForm())
        {
            @Html.AntiForgeryToken()
            <p>
                <input type="submit" value="@CloudFranceTriple.WebRole.Properties.Resources.ButtonDelete" />
            </p>
        }
        @Html.Partial("_PrivateMessageBackToList")
    </section>
</div>
